/*
 * Copyright (c) 2018-2025 Tencent. All Rights Reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */

namespace TencentCloud.Ocr.V20181119.Models
{
    using Newtonsoft.Json;
    using System.Collections.Generic;
    using TencentCloud.Common;

    public class MLIDPassportOCRResponse : AbstractModel
    {
        
        /// <summary>
        /// Passport ID
        /// </summary>
        [JsonProperty("ID")]
        public string ID{ get; set; }

        /// <summary>
        /// Name
        /// </summary>
        [JsonProperty("Name")]
        public string Name{ get; set; }

        /// <summary>
        /// Date of birth
        /// </summary>
        [JsonProperty("DateOfBirth")]
        public string DateOfBirth{ get; set; }

        /// <summary>
        /// Gender (F: female, M: male)
        /// </summary>
        [JsonProperty("Sex")]
        public string Sex{ get; set; }

        /// <summary>
        /// Expiration date
        /// </summary>
        [JsonProperty("DateOfExpiration")]
        public string DateOfExpiration{ get; set; }

        /// <summary>
        /// Issuing country
        /// </summary>
        [JsonProperty("IssuingCountry")]
        public string IssuingCountry{ get; set; }

        /// <summary>
        /// Country/region code
        /// </summary>
        [JsonProperty("Nationality")]
        public string Nationality{ get; set; }

        /// <summary>
        /// This field is deprecated and will always return an empty array. Usage is not recommended.
        /// </summary>
        [JsonProperty("Warn")]
        [System.Obsolete]
        public long?[] Warn{ get; set; }

        /// <summary>
        /// Identity photo
        /// </summary>
        [JsonProperty("Image")]
        public string Image{ get; set; }

        /// <summary>
        /// This field is deprecated and will always return "1". Usage is not recommended.
        /// </summary>
        [JsonProperty("AdvancedInfo")]
        [System.Obsolete]
        public string AdvancedInfo{ get; set; }

        /// <summary>
        /// The first row of the machine-readable zone (MRZ) at the bottom
        /// </summary>
        [JsonProperty("CodeSet")]
        public string CodeSet{ get; set; }

        /// <summary>
        /// The second row of the MRZ at the bottom
        /// </summary>
        [JsonProperty("CodeCrc")]
        public string CodeCrc{ get; set; }

        /// <summary>
        /// The surname.
        /// Note: This field may return null, indicating that no valid values can be obtained.
        /// </summary>
        [JsonProperty("Surname")]
        public string Surname{ get; set; }

        /// <summary>
        /// The given name.
        /// Note: This field may return null, indicating that no valid values can be obtained.
        /// </summary>
        [JsonProperty("GivenName")]
        public string GivenName{ get; set; }

        /// <summary>
        /// Type (in Machine Readable Zone)
        /// </summary>
        [JsonProperty("Type")]
        public string Type{ get; set; }

        /// <summary>
        /// Document content in Information Zone
        /// </summary>
        [JsonProperty("PassportRecognizeInfos")]
        public PassportRecognizeInfos PassportRecognizeInfos{ get; set; }

        /// <summary>
        /// Card Warning Information
        /// 
        /// -9101 Alarm for covered certificate,
        /// -9102 Alarm for photocopied certificate,
        /// -9103 Alarm for photographed certificate,
        /// -9104 Alarm for PS certificate,
        /// -9107 Alarm for reflective certificate,
        /// -9108 Alarm for blurry image,
        /// -9109 This capability is not enabled.
        /// </summary>
        [JsonProperty("WarnCardInfos")]
        public long?[] WarnCardInfos{ get; set; }

        /// <summary>
        /// The number of cards detected in the input image.(Currently supported only in ap-bangkok region)
        /// </summary>
        [JsonProperty("CardCount")]
        public long? CardCount{ get; set; }

        /// <summary>
        /// The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
        /// </summary>
        [JsonProperty("RequestId")]
        public string RequestId{ get; set; }


        /// <summary>
        /// For internal usage only. DO NOT USE IT.
        /// </summary>
        public override void ToMap(Dictionary<string, string> map, string prefix)
        {
            this.SetParamSimple(map, prefix + "ID", this.ID);
            this.SetParamSimple(map, prefix + "Name", this.Name);
            this.SetParamSimple(map, prefix + "DateOfBirth", this.DateOfBirth);
            this.SetParamSimple(map, prefix + "Sex", this.Sex);
            this.SetParamSimple(map, prefix + "DateOfExpiration", this.DateOfExpiration);
            this.SetParamSimple(map, prefix + "IssuingCountry", this.IssuingCountry);
            this.SetParamSimple(map, prefix + "Nationality", this.Nationality);
            this.SetParamArraySimple(map, prefix + "Warn.", this.Warn);
            this.SetParamSimple(map, prefix + "Image", this.Image);
            this.SetParamSimple(map, prefix + "AdvancedInfo", this.AdvancedInfo);
            this.SetParamSimple(map, prefix + "CodeSet", this.CodeSet);
            this.SetParamSimple(map, prefix + "CodeCrc", this.CodeCrc);
            this.SetParamSimple(map, prefix + "Surname", this.Surname);
            this.SetParamSimple(map, prefix + "GivenName", this.GivenName);
            this.SetParamSimple(map, prefix + "Type", this.Type);
            this.SetParamObj(map, prefix + "PassportRecognizeInfos.", this.PassportRecognizeInfos);
            this.SetParamArraySimple(map, prefix + "WarnCardInfos.", this.WarnCardInfos);
            this.SetParamSimple(map, prefix + "CardCount", this.CardCount);
            this.SetParamSimple(map, prefix + "RequestId", this.RequestId);
        }
    }
}

